package com.echo.code.spring.springbootdemo.async;

import lombok.extern.slf4j.Slf4j;
import org.springframework.aop.interceptor.AsyncUncaughtExceptionHandler;

import java.lang.reflect.Method;

/**
 * Description
 *
 * @author baiyp
 * @version 1.0.0
 * @date 2019/04/28
 */
@Slf4j
public class ExceptionHandler implements AsyncUncaughtExceptionHandler {
  @Override
  public void handleUncaughtException(Throwable ex, Method method, Object... params) {
    log.error("async occur error", ex);
  }
}
